package com.wln.kms.kms.service.impl;

import org.springframework.stereotype.Service;
import java.util.Map;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.wln.common.utils.PageUtils;
import com.wln.common.utils.Query;

import com.wln.kms.kms.dao.BargainRecordDao;
import com.wln.kms.kms.entity.BargainRecordEntity;
import com.wln.kms.kms.service.BargainRecordService;


@Service("bargainRecordService")
public class BargainRecordServiceImpl extends ServiceImpl<BargainRecordDao, BargainRecordEntity> implements BargainRecordService {

    @Override
    public PageUtils queryPage(Map<String, Object> params) {
        QueryWrapper<BargainRecordEntity> wrapper = new QueryWrapper<>();
        String activityHid = (String) params.get("activityHid");
        wrapper.eq("activity_hid",activityHid);
        IPage<BargainRecordEntity> page = this.page(
                new Query<BargainRecordEntity>().getPage(params),
                wrapper
        );
        return new PageUtils(page);
    }

}